<template>
  <div>
    this is vue Demo
    <div @click="increment">+ mapActions</div>
    <div @click="handleIncrement">+ store</div>
    <State></State>
  </div>
</template>

<script>
import { mapActions } from 'vuex';
import State from './state';
export default {
  components: {
    State,
  },
  props: {},
  data() {
    return {
    };
  },
  computed: {},
  watch: {},
  created() {},
  mounted() {},
  methods: {
    ...mapActions('vuexDemo', ['increment']),
    handleIncrement() {
      this.$store.dispatch('vuexDemo/increment');
    },
  },
};
</script>
<style>

</style>
